/**
 * @Author: Sagan
 * @Date: 2020/09/19 18:46
 */
package module

import (
	"gitee.com/big_meteor/godash/validate/constant"
	"gitee.com/big_meteor/godash/validate/function"
)

// 是否不等于某个值
// 支持的类型：int、uint、float
func Neq(v interface{}, num float64) (bool, error) {
	value, flag := function.ToFloat64(v)
	if false == flag {
		return false, constant.ERROR_NEQ_UDT
	}

	return value != num, nil
}
